﻿
namespace SortAndDatastruct
{
    /// <summary>
    /// 排序算法的抽象类
    /// </summary>
    abstract class ISort
    {
        /// <summary>
        /// 排序接口
        /// </summary>
        /// <param name="array">带排序的数组</param>
        internal abstract void Sort(ref int[] array);
        /// <summary>
        /// 显示排序数组
        /// </summary>
        /// <param name="array">带排序的数组</param>
        internal void ShowResult(ref int[] array) {
            if (array == null || array.Length < 1) return;
            foreach (var item in array) {
                System.Console.Write(item+" ");
            }
        }
    }
}
